package com.demo.gateway.sentinel.api;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;

/**
 * 模拟feign的Api功能，网关可以访问微服务内部接口来获取限流的配置等信息
 * {@link com.demo.gateway.app.controller.ConfigController}
 */
@FeignClient(name = "${cbpc.feign.authcenter.server:gateway-demo-app}",path = "/config")
public interface ConfigClient {
        /**
         * 获取限流配置
         * @return 是否限流
         */
        @GetMapping("")
        boolean config();
}
